 <link rel="stylesheet" href="../Public/style/forum.css" />
<style>
img{max-width:100%;}
</style>
 	 <div id="top">
		 <div class="head2 clear">
			 <div class="account sprite_icon">
				 <a href="javascript:history.go(-1)"><span class="icon1 icon_com"></span></a>
			 </div>
			   {if $title}
			    <div class="title">{$title}</div> 
               {else}
                <div class="title">{$seo_title}</div> 
               {/if}<div class="search sprite_icon">
			    <!-- <span class="icon2 icon_com">-->
			 </div>
		 </div>
	 </div> 
     
  <include file="Mobile:nav"/>    
     
      <div class="content P_color">
		 
	     <div class="post_list inside">
			 <div class="section3">
				 <div class="section Padding">
					 <a href="javascript:;">
						 <div class="title clear">
							 <div class="little_title">{$theme['title']}</div>
							<!-- <span class="icon1 com"></span>-->
							{if $theme['essence']==1 }  <span class="icon2 com"></span>{/if}
							 {if $theme['top']==1 }<span class="icon2-1 com"></span>{/if}
							<!-- <span class="icon2-2 com"></span>-->
						 </div>
						 <div class="I_icon clear">
							 <span class="icon3 com"></span><em>{$theme['hits']}</em>
                             <span class="icon4 com"></span><em>{$theme['like_num']}</em>
                             <span class="icon5 com"></span><em>{$theme['reply_num']}</em>
						 </div>
					 </a>
				 </div>
			 </div>
	     </div>
	     

		 <div class="publish Padding">
			 
			 <div class="name">
				 <span>{$theme['username']}</span>
				 <strong>楼主</strong>
				 <p class="time">{$theme['createtime']|remianday=###}</p>
			 </div>

			 <div class="mes" style="word-wrap:break-word;">
				{$theme['content']}
			 </div>

			
			 <div class="extra clear">
				 <div class="left">
					 <span class="icon1 com"></span><em>{$theme['keep_num']}</em><span class="icon2 com"></span><em>{$theme['like_num']}</em>
				 </div>
				 
				 <div class="right">
					 <a href="index.php?g=Mobile&m=Zforum_reply&a=index&id={$theme['id']}&plateid={$plate['id']}&userid={$theme['userid']}">
                     <span class="icon3 com"></span><em class="sb">只看该作者</em><span class="icon4 com"></span>
				     </a>
                 </div>
			 </div>

		 </div>
      <volist name="list" id="r" key="k">
        {if $k!=1}
         <ul class="comment_list forum_comment F_topBorder">
             <li class="clear top_border">
                 <div class="floor">{$k}#</div>
                 <div class="pic">
                     <img src="{$r['avatar']}" alt="" />
                 </div>
                 <div class="info">
                     <strong>{$r['username']}</strong>
                     <span>{$r['createtime']|remianday=###}</span>
                     <em>说：</em>
                     <div class="mes" style="width:90%;">{php echo strip_tags($r['content'])}</div>
                 </div>
                <a href="?g=Mobile&m=Zforum_reply&a=add&id=7&theme_id={$theme['id']}&pid={$r['id']}&re_name={$r['username']}"> <div class="reply">回复<!--<span>(3)</span>&or;--></div></a>
             </li>
                   <div>
                       <?php  $field='jg_Zforum_reply.*,jg_user.avatar ';
                              $list=M('Zforum_reply')->field($field)->where('pid='.$r['id'])->join('jg_user ON jg_Zforum_reply.userid = jg_user.id')->order('jg_Zforum_reply.id asc')->limit(8)->select();
                             foreach($list as $kk=>$v){      
                           ?>
                    
                             <li class="clear dashed no_dashed" style="width:90%; margin-left:10%">
                                 <div class="pic spacing">
                                     <img src="{$v['avatar']}" alt="" />
                                 </div>
                                 <div class="info">
                                     <strong style=" font-size:12px">{$v['username']}</strong>
                                     <span>{if $v['re_name']}回复{/if}</span>
                                     <em>{if $v['re_name']}{$v['re_name']}{/if}</em>
                                     <p class="mes" style=" font-size:8px">{php echo strip_tags($v['content'])}</p>
                                 </div>
                                 
                                  <a href="?g=Mobile&m=Zforum_reply&a=add&id=7&theme_id={$theme['id']}&pid={$r['id']}&re_name={$v['username']}"><div class="reply">回复</div> </a>
                             </li>
                    <?php } ?> 
                   </div>
         </ul>
         {/if}
       </volist>  
         

		 
	 
		 <div class="psges">{$pages}</div>
 {if cookie('auth')} 
<form action="index.php?g=Mobile&m=Zforum_reply&a=insert" method="post"  >
		 <div class="padding_section clear border_bottom forum_discuss">
			 <div class="discuss clear">
				 <div class="pic">
					 <img src="../Public/images/effect_pic4.jpg" alt="" />
				 </div>
				 <textarea name="reply[content]" id="" cols="30" rows="10" placeholder="添加评论~~" class="discuss_box"></textarea>
                 
                    <input type="hidden" name="reply[theme_id]" value="{$theme['id']}">
                    <input type="hidden" name="mes[theme_id]" value="{$theme['id']}">
                    <input type="hidden" name="mes[theme_title]" value="{$theme['title']}">
                    <input type="hidden" name="mes[userid]" value="{$theme['userid']}">
                    <input type="hidden" name="mes[username]" value="{$theme['username']}">
                    <input type="hidden" name="mes[url]" value="index.php?{$_SERVER['QUERY_STRING']}"
                 
			 </div>

			 <input type="submit" class="add_discuss" value="添加评论" />
		 </div>
    </form>     
{else} 
        <div class="padding_section clear border_bottom forum_discuss">
			 <div class="discuss clear" style="line-height: 35px; text-align:center"> 
				 <div class="pic" style="margin-left:10%">
					 <img src="../Public/images/effect_pic4.jpg" alt="" />
				 </div>
				您需要登录后才可以回帖&nbsp;&nbsp;&nbsp;
       <span ><a style="color:#06F" href="{:URL('Mobile-Login/index')}">登录</a></span>&nbsp;|&nbsp;
       <span ><a style="color:#06F" href="{:URL('Mobile-Register/index')}"/>注册</a></span> 
			 </div>

			
		 </div>


{/if}        
	 </div>